#include "widget.h"
#include "ui_widget.h"

Widget::Widget(QWidget *parent)
    : QWidget(parent)
    , ui(new Ui::Widget)
{
    ui->setupUi(this);

    ui->comboBox->addItem("2020");
    ui->comboBox->addItem("2021");
    ui->comboBox->addItem("2022");

    ui->comboBox_2->addItem("法学院");
    ui->comboBox_2->addItem("信息学院");
    ui->comboBox_2->addItem("土木学院");

    ui->comboBox_3->addItem("101");
    ui->comboBox_3->addItem("201");
    ui->comboBox_3->addItem("301");
}

Widget::~Widget()
{
    delete ui;
}


void Widget::on_pushButton_clicked()
{
    qDebug() << "入学年份：" << ui->comboBox->currentText() << endl
             << "所在院系：" << ui->comboBox_2->currentText() << endl
             << "所在班级：" << ui->comboBox_3->currentText();
}
